Subaccount Management
A Subaccount is a way to manage your clients by separating your main account (Avenia API Main Account or BA) from others.
info
The diagram shows that multiple accesses can manage subaccounts related to the main account.
Create Subaccount
When creating a Subaccount, you gain the ability to perform operations such as: KYC, OPERATIONS, BENEFICIARY BANK ACCOUNT, BENEFICIARY WALLETS, and other Avenia API features.
HTTP POST Request
https://api.sandbox.avenia.io:10952/v2/account/sub-accounts
Fields
Field | Type | Description |
---|---|---|
accountType | string | Type related to this subaccount (INDIVIDUAL) |
name | string | Name for easier identification of this Subaccount |
Sample JSON Body
{
"accountType": "INDIVIDUAL",
"name": "Marcos subaccount ricoaaaaaaaaaaa"
}
cUrl Example
curl -X POST "https://api.sandbox.avenia.io:10952/v2/account/sub-accounts" \
-H "Content-Type: application/json" \
-d '{
"accountType": "INDIVIDUAL",
"name": "jane doe"
}'
JSON Response
The response will include the ID linked to the created Subaccount.
{
"id": "c852df87-ac61-4259-8242-6451658dfedb"
}
List All Subaccounts
To view all your Subaccounts, use the list endpoint with these parameters:
Fields
Field | Type | Description |
---|---|---|
name | string | Search for names containing specific characters |
cursor | string | Pagination cursor to advance through results |
HTTP GET Request
https://api.sandbox.avenia.io:10952/v2/account/sub-accounts
cUrl Example
curl -X GET "https://api.sandbox.avenia.io:10952/v2/account/sub-accounts"
JSON Response
{
"cursor": "MTEwLTE3NDMwMjkzNTUyODE=",
"subAccount": [
{
"subAccountId": "2eea0102-dabe-4ab6-8707-0817aa52dfe4",
"mainAccountId": "3657c184-854c-4a71-98b0-9fc8e2960ba8",
"createdAt": "2025-03-27T09:59:59.099865Z",
"accountInfo": {
"id": "87b3ab56-463c-4207-ae31-4d2bd26dc66a",
"accountType": "INDIVIDUAL",
"name": "Ada Doe"
}
}
// ... other subaccounts
]
}
Get Specific Subaccount
Retrieve details of a specific Subaccount using its ID.
HTTP GET Request
https://api.sandbox.avenia.io:10952/v2/account/sub-accounts/SUBACCOUNT-ID-HERE
cUrl Example
curl -X GET "https://api.sandbox.avenia.io:10952/v2/account/sub-accounts/SUBACCOUNT-ID-HERE"
JSON Response
{
"subAccountId": "2eea0102-dabe-4ab6-8707-0817aa52dfe4",
"mainAccountId": "3657c184-854c-4a71-98b0-9fc8e2960ba8",
"createdAt": "2025-03-27T09:59:59.099865Z",
"accountInfo": {
"id": "87b3ab56-463c-4207-ae31-4d2bd26dc66a",
"accountType": "INDIVIDUAL",
"name": "Ada Doe"
}
}
Conclusion
You can now fully utilize Subaccount capabilities. Remember to include the subAccountId
parameter in endpoints that allow Subaccount operations.